package com.cuiweiyou.gdx_1_9_10.event

import com.badlogic.gdx.scenes.scene2d.InputEvent
import com.badlogic.gdx.scenes.scene2d.utils.ClickListener
import com.cuiweiyou.gdx_1_9_10.actor.DemoActor2


/**
 * author GaoPC
 * date 2020/7/7 18:15
 * description
 */
class Actor2ClickListener : ClickListener() {
    override fun clicked(event: InputEvent?, x: Float, y: Float) {
        val actor: DemoActor2 = event!!.listenerActor as DemoActor2
        actor.body.setLinearVelocity(20f,20f)
    }
}